import { Component } from "react";

class List extends Component {
    constructor(props) {
        super(props);
        console.log("1->constructor");
    }
    componentWillMount() {
        console.log("2->componentWillMount");
    }
    componentDidMount() {
        console.log("4->componentDidMount");
    }
    render() {
        console.log("3->render");
        return (
            <>
                {this.props.children}
                <ul className='list-group'>
                    <li className='list-group-item'>第一项</li>
                    <li className='list-group-item'>第二项</li>
                    <li className='list-group-item'>第三项</li>
                </ul>
            </>
        );
    }
}

export default List;
